import Vue from 'vue'
import Router from 'vue-router'
import Home from './views/Home.vue'
import hotsong from './views/hotsong.vue'
import search from './views/search.vue'
import song from '@/components/song.vue'
import playList from '@/components/playList.vue'
import downApp from '@/components/downApp.vue'
import loginSucceed from './views/loginSucceed.vue'

Vue.use(Router)

export default new Router({
  mode: 'history',
  base: process.env.BASE_URL,
  routes: [
    {
      path: '/',
      name: 'home',
      alias: '/home',
      component: Home
      
    },
    {
    	path:'/song',
    	component: song
    },
    {
      path: '/about',
      name: 'about',
      // route level code-splitting
      // this generates a separate chunk (about.[hash].js) for this route
      // which is lazy-loaded when the route is visited.
      component: () => import(/* webpackChunkName: "about" */ './views/About.vue')
    },
    {
    	path:'/hotsong',
    	component: hotsong
    },{
    	path:'/search',
    	component: search
    },
    {
    	path:"/playList",
    	component: playList
    },
    {
    	path:"/downApp",
    	component:downApp
    },
    {
    	path:"/loginSucceed",
    	component:loginSucceed,
    	meta:{
    		download:true
    	}
    }
  ]
})
